package edu.ctbu.insurance.service.userEmail;

import edu.ctbu.insurance.bean.User;
import edu.ctbu.insurance.vo.UserVo;

public class UserVoToUser {
    public static User toUser(UserVo userVo) {
        User user = new User();

        user.setId(userVo.getId());
        user.setUserAccount(userVo.getUserAccount());
        user.setUserName(userVo.getUserName());
        user.setUserPwd(userVo.getUserPwd());
        user.setUserCompany(userVo.getUserCompany());
        user.setUserSex(userVo.getUserSex());
        user.setUserEmail(userVo.getUserEmail());
        user.setUserPhoneNumber(userVo.getUserPhoneNumber());
        user.setUserIntroduction(userVo.getUserIntroduction());
        user.setUserHeadImg(userVo.getUserHeadImg());
        user.setUserBirthday(userVo.getUserBirthday());
        user.setUserAddress(userVo.getUserAddress());
        user.setUserRole(userVo.getUserRole());

        return user;
    }
}
